recode
{dplyr}
Recode a variable
c
{base}
Combine values/vectors into a vector
ls
{base}
Return a vector of character strings giving the names of the objects in the specified environment
summary
{base}
Obtain summary statistics or detailed regression output
scale_x_continuous
{GGPLOT2}
Customise continuous x axis
setwd
{base}
Set Working Directory
theme_classic
{GGPLOT2}
A minimalistic theme with no gridlines
xlab
{GGPLOT2}
Label the x axis (ggplot)
vcovHC
{sandwich}
Heteroscedasticity-consistent estimation of the covariance matrix of the coefficient estimates
ifelse
{base}
Return a or b depending on the value of test
pchisq
{stats}
Gives the distribution function of the chi-squared distribution
coeftest
{lmtest}
Inference for Estimated Coefficients
droplevels
{base}
Drop Unused Levels from Factors
chisq.test
{stats}
Chi-Squared test (e.g. for cross-tabulations)
with
{base}
evaluate expression in the context of a data frame
read_dta
{haven}
Read a .dta file (Stata data)
ordered
{dplyr}
Create an ordered factor
set.seed
{base}
Initialise a pseudorandom number generator.
select
{dplyr}
Select columns from a tibble/data frame
subset
{base}
Return subsets of vectors, matrices or data frames which meet conditions.
geom_smooth
{GGPLOT2}
Generates a smoothed conditional means curve / line
names
{base}
Retrieve names of a list/vector
leveneTest
{car}
Computes Levene’s test for homogeneity of variance across groups.
library
{base}
Load an R package
ggplot
{GGPLOT2}
Create a ggplot graph
bptest
{lmtest}
Breusch-Pagan Test for Homoscedasticity
as.numeric
{base}
Coerce a vector to numeric
cut
{base}
Convert Numeric to Factor
sample_frac
{dplyr}
Sample a fraction of observations from a data frame
t.test
{stats}
Performs one and two sample t-tests on vectors of data.
confint
{stats}
Calculate confidence Intervals for Model Parameters
table
{base}
Obtain frequency table of a variable/cross-tabulation of two variables
filter
{dplyr}
Filter out rows of a data frame according to logical vector
geom_point
{GGPLOT2}
Generates a scatter plot
relevel
{stats}
Reorder Levels of Factor
is.element
{base}
Check if a value is element of a vector
log
{base}
log (default base = e)
rm
{base}
Remove objects
mutate
{dplyr}
Modify/create a column in a data frame
levels
{base}
Get levels of a factor
as.character
{base}
Coerce a vector to character
prop.table
{base}
Transform frequency table into table of proportions
prop.test
{stats}
Test of Equal or Given Proportions
lm
{base}
Fit a linear model
stargazer
{stargazer}
Create a regression output table
read_excel
{readxl}
Read an Excel file
vif
{car}
Calculate Variance Inflation Factor
ylab
{GGPLOT2}
Label the y axis (ggplot)
scale_y_continuous
{GGPLOT2}
Customise continuous y axis
aes
{GGPLOT2}
Construct aesthetic mapping of a ggplot graph
nobs
{gdata}
Compute the number of non-missing observations
resid
{stats}
Extracts model residuals from objects returned by modeling functions
attach
{base}
Attach Set of R Objects to Search Path
read.csv
{utils}
Read a csv file to data frame. Specify stringsAsFactors = FALSE to keep all string columns as characters
The end!